-- GENERATED SPELL FOR [Murkgill Lord] --


function spell0_4460(pUnit, Event) --@Frost Armor,Self--
pUnit:FullCastSpellOnTarget(12544,pUnit)
pUnit:RegisterEvent('Sorts_4460', 0, 1)
end

function spell1_4460(pUnit, Event) --@Frost Nova,Self--
pUnit:FullCastSpellOnTarget(38033,pUnit)
pUnit:RegisterEvent('Sorts_4460', 10000, 1)
end

function spell2_4460(pUnit, Event) --@Frostbolt,n/a--
pUnit:FullCastSpellOnTarget(9672,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_4460', 7000, 1)
end

function Sorts_4460(pUnit, Event)
local choix_sorts_4460 = math.random(0, 2)
if choix_sorts_4460 == 0 then
pUnit:RegisterEvent('spell0_4460', 1, 1)
end
if choix_sorts_4460 == 1 then
pUnit:RegisterEvent('spell1_4460', 1, 1)
end
if choix_sorts_4460 == 2 then
pUnit:RegisterEvent('spell2_4460', 1, 1)
end
end

function mob4460_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_4460', math.random(1500, 3000), 1)
end

function mob4460_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob4460_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob4460_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(4460, 1, 'mob4460_Action')
RegisterUnitEvent(4460, 2, 'mob4460_Leave')
RegisterUnitEvent(4460, 3, 'mob4460_Kill')
RegisterUnitEvent(4460, 4, 'mob4460_Die')
